package com.xiaoyu.lanling.feature.moment.viewholder.publish

import android.view.LayoutInflater
import android.view.View
import android.view.ViewGroup
import com.xiaoyu.lanling.R
import com.xiaoyu.lanling.event.moment.publish.AddMediaEvent
import com.xiaoyu.lanling.feature.moment.datamodel.publish.MediaAddItem

class MediaAddViewHolder : MediaBaseViewHolder<MediaAddItem>() {

    override fun createView(layoutInflater: LayoutInflater, parent: ViewGroup): View? {
        val view = layoutInflater.inflate(R.layout.moment_publish_add_item, parent, false)
        view.setOnClickListener(sOnClickHandler)
        return view
    }

    override fun showData(position: Int, itemData: MediaAddItem) {}

    companion object {

        private val sOnClickHandler = View.OnClickListener { AddMediaEvent().post() }
    }
}
